﻿using System;
using System.Collections.Generic;
using System.ComponentModel;
using System.Data;
using System.Drawing;
using System.Linq;
using System.Text;
using System.Windows.Forms;
using System.Security.Cryptography;
using System.Data.SqlClient;

namespace CourseRecommend
{
   public class SQLConnector : RegisterForm 
    {
        public void createConnection()
        {
            string connectionString = @"Data Source=.\SQLEXPRESS;AttachDbFilename=|DataDirectory|\Catalog.mdf;Integrated Security=True;User Instance=True";
            SqlConnection myConnection = new SqlConnection(connectionString);

            try
            {
                myConnection.Open();
                MessageBox.Show("connected");
            }
            catch (Exception e)
            {
                MessageBox.Show(e.ToString());
            }
            

        }
    }
}
